home *** CD-ROM | disk | FTP | other *** search
/ Linux Cubed Series 7: Sunsite / Linux Cubed Series 7 - Sunsite Vol 1.iso / alpha / dipc / dipc-0.000 / dipc-0 / dipc-0.15 / dipc.install < prev    next >
Text File  |  1996-07-21  |  2KB  |  80 lines

  1. #! /bin/sh
  2.  
  3. KERNELPATH=/usr/src/linux
  4.  
  5. INCLUDE=$KERNELPATH/include/linux
  6. IPCPATH=$KERNELPATH/ipc
  7. ARCH_MM=$KERNELPATH/arch/i386/mm
  8.  
  9. echo
  10. echo This script partially installs the DIPC V0.15 software.
  11. echo It was written on a Slackware 2.3 \(Kernel 1.2.8\) Linux box.
  12. echo
  13. if test `whoami` != root; then
  14.  echo You should be the root to run this script.
  15.  exit 1
  16. else
  17.  echo Press RETURN to continue, or Control-C to break...
  18.  read
  19. fi
  20.  
  21. echo copying kernel files...
  22. cd kernel
  23. for file in fault.c
  24. do
  25.  # don't overwrite the original: copy it once
  26.  if test ! -s $ARCH_MM/non_dipc_$file; then
  27.   mv $ARCH_MM/$file $ARCH_MM/non_dipc_$file 
  28.  fi
  29.  cp $file $ARCH_MM
  30. done
  31.  
  32. for file in Makefile shm.c msg.c sem.c dipc.c util.c 
  33. do
  34.  if test $file != dipc.c; then
  35.   if test ! -s $IPCPATH/non_dipc_$file; then
  36.    mv $IPCPATH/$file $IPCPATH/non_dipc_$file
  37.   fi
  38.  fi
  39.  cp $file $IPCPATH
  40. done
  41.  
  42. for file in ipc.h dipc.h 
  43. do
  44.  if test $file != dipc.h; then
  45.   if test ! -s $INCLUDE/non_dipc_$file; then
  46.    mv $INCLUDE/$file $INCLUDE/non_dipc_$file
  47.   fi
  48.  fi 
  49.  cp $file  $KERNELPATH/include/linux
  50. done
  51.  
  52. echo You can find the original kernel files with \'non_dipc_\' added to them.
  53. cd ..
  54.  
  55. cd dipcd
  56. echo creating /etc/dipc.conf...
  57. cp dipc.conf /etc
  58.  
  59. echo making the dipcd program...   
  60. make
  61.  
  62. echo creating /usr/sbin/dipcd...
  63. cp dipcd /usr/sbin
  64.  
  65. echo adding dipcd to /etc/rc.d/rc.local...
  66. echo "/usr/sbin/dipcd 2>/tmp/dipcd_mess" >> /etc/rc.d/rc.local
  67. cd ..
  68.  
  69. echo
  70. echo PLEASE MANUALLY DO THE FOLLOWING:
  71. echo *\) Make sure swapping to disk is enabled \(mkswap and swapon\).
  72. echo *\) Add a user with the name 'dipcd' \(adduser\).
  73. echo *\) Edit the file /etc/dipc.conf to write the correct addresses for this
  74. echo "   machine and the referee machine."
  75. echo *\) Reconfigure your kernel to make sure System V IPC is present.
  76. echo *\) Make and install the new kernel.
  77. echo
  78. echo Read the files quick.start and docs/installation for more information.
  79. echo
  80.